<style scoped>
.main{
    height: 100%;
}
</style>

<template>
    <div class="main">
        <Main>
            <router-view></router-view>
        </Main>
    </div>
</template>

<script>
import Main from '@/components/layout/theme2'
import { mapActions } from 'vuex'

export default {
  data () {
    return {
      name: '首页'
    }
  },
  components: {
    Main
  },
  methods: {
    ...mapActions([
      'getUserInfo',
      'getPhpMenusData',
      'getJavaMenusData',
      'setBreadCrumb'
    ])
  },
  mounted () {
    this.getUserInfo().then(resx => {})
    // TODO 如果是java菜单还需要调用综合菜单
    if (this.$config.phpMenu) {
      this.getPhpMenusData(1)
    } else {
      this.getJavaMenus(22)
    }
    // this.setBreadCrumb()
  }
}
</script>
